package com.wanmait.recycle.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.wanmait.recycle.mapper.LogMapper;
import com.wanmait.recycle.pojo.Log;
import com.wanmait.recycle.service.LogService;
import com.wanmait.recycle.util.Pager;
@Service
@Transactional
public class LogServiceImpl implements LogService {

	@Resource
	private LogMapper logMapper;
	
	@Override
	public void insert(Log object) {
		// TODO Auto-generated method stub

	}

	@Override
	public void update(Log object) {
		// TODO Auto-generated method stub

	}

	@Override
	public void delete(Integer id) {
		logMapper.delete(id);

	}

	@Override
	public void delete(String ids) {
		// TODO Auto-generated method stub

	}

	@Override
	public Log findById(Integer id) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public List<Log> findAll() {
		// TODO Auto-generated method stub
		return logMapper.findAll();
	}

	@Override
	public int getDataCount() {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public List<Log> findAll(Pager pager) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public List<Log> findAll(Log object) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public int getDataCount(Log object) {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public List<Log> findAll(Pager pager, Log object) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public void save(Log log) {
		// TODO Auto-generated method stub
		logMapper.save(log);
	}

	@Override
	public void deleteLogs(String ids) {
		ids = ids.substring(0, ids.length()-1);
		String[] nn =ids.split(",");
		
		logMapper.deleteLogs(nn);
	}

	@Override
	public List<Log> findAllBySearch(String searchStr, String beginTime, String endTime) {
		return logMapper.findAllBySearch(searchStr, beginTime, endTime);
	}

	
}
